package nothing;

import java.util.List;
import org.apache.log4j.Logger;
import nothing.dao.ChefDao;
import nothing.model.Equipment;
import nothing.model.Food;
import nothing.model.FoodStorageType;
import nothing.model.Ingredient;
import nothing.model.Measurement;
import nothing.model.Recipe;
import nothing.model.RecipeEquipment;
import nothing.model.RecipeStep;
import nothing.model.RecipeType;
import nothing.model.Step;
import nothing.model.Type;

public class Chef  {
    static Logger log = Logger.getLogger(Chef.class);
    private ChefDao chefDao= null;

    public Chef(ChefDao chefDao){
        this.setChefDao(chefDao);
    }
    public List<Equipment> getAllEquipment(){
        return chefDao.getEquipmentDao().getAll();                
    }
    public Equipment storeEquipment(Equipment equipment){
        return chefDao.getEquipmentDao().save(equipment);
    }
     public FoodStorageType storeFoodStorageType(FoodStorageType foodStorageType){
        return chefDao.getFoodStorageTypeDao().save(foodStorageType);
    }
     public RecipeEquipment storeRecipeEquipment(RecipeEquipment recipeEquipment){
        return chefDao.getRecipeEquipmentDao().save(recipeEquipment);
    }
   public RecipeType storeRecipeEquipment(RecipeType recipeType){
        return chefDao.getRecipeTypeDao().save(recipeType);
    }
    public List<Step> getAllStep(){
        return chefDao.getStepDao().getAll();                
    }
    public Step storeStep(Step step){
        return chefDao.getStepDao().save(step);
    }
    public Type storeType(Type type){
        return chefDao.getTypeDao().save(type);
    }
    public List<Measurement> getAllMeasurement(){
        return chefDao.getMeasurementDao().getAll();                
    }
    public Measurement storeMeasurement(Measurement measurement){
        return chefDao.getMeasurementDao().save(measurement);
    }
    public Food storeFood(Food food){
        return chefDao.getFoodDao().save(food);
    }
    public Ingredient storeIngredient(Ingredient ingredient){
        return chefDao.getIngredientDao().save(ingredient);
    }
    public RecipeStep storeRecipeStep(RecipeStep recipeStep){
        return chefDao.getRecipeStepDao().save(recipeStep);
    }
    public Recipe storeRecipe(Recipe recipe){
        return chefDao.getRecipeDao().save(recipe);
    }

    public void setChefDao(ChefDao chefDao) {
        this.chefDao = chefDao;
    }
    
    
}
